package happy.town.case_student;

import java.util.ArrayList;

/**
 * @BelongsProject: case_student
 * @BelongsPackage: happy.town.case_student
 * @Author: ByHappy  (Email:1300985301@qq.com)
 * @CreateTime: 2023-08-08 00:55
 * @Description:
 * @Version: 1.0
 **/
public class StudentServiceImpl implements StudentService {


    private StudentDao dao = new StudentDaoImpl();

    /*
        查询所有学生信息
    */
    @Override
    public ArrayList<Student> findAll() {
        return dao.findAll();
    }


    @Override
    public Student findById(Integer id) {
        return dao.findById(id);
    }

    @Override
    public int insert(Student stu) {
        return dao.insert(stu);
    }

    @Override
    public int update(Student stu) {
        return dao.update(stu);
    }

    @Override
    public int delete(Integer id) {
        return dao.delete(id);
    }
}
